Oracle PL/SQL wrappers for Address Object on Linux

*************
INTRODUCTION
*************

This file describes how to setup and use the Oracle PL/SQL wrapper code with Melissa DATA's Address Object library.


*************
PREREQUISITES
*************

To make use of the Address Object PL/SQL Wrapper you will need:

* An installation of Oracle 11 or later.

* The Melissa DATA Address Object library and misc. data files installed.

	Library = libmdAddr.so 
	CASS Data Files = mdAddr.dat,mdAddr.lic,mdAddr.nat,mdAddr.str
	DPV Data Files = dph.dte,dph.hsa,dph.hsc,dph.hsf,dph.hsv,dph.hsx, lcd
	SuiteLink Files = mdSteLink.dat
	LACSLink Files = mdLACS.dat
	AddressPlus Files = mdSuiteFinder.db
	EWS File = ews.txt

These files are installed automatically if you run setup_main.sh installer from the DQSuite disc.

You will need to know the location of these items in order to install and execute the PL/SQL wrapper. 


*************
Installation
*************

Copy the entire folder that contains this readme.txt into a local directory on your computer.
Copy libmdAddr.so to the $ORACLE_HOME/lib directory, or optionally set EXTPROC_DLLS to ANY with the Path set to libmdAddr.so and restart the TNS listener.

Make sure to use the Address Object library for your architecture, ie: 32/64 and included GCC version. They can be found on the DQSuite disc at the following locations:
	/address/linux/gcc32_32bit
	/address/linux/gcc34_32bit
	/address/linux/gcc34_64bit
	
******
Setup
******

GRANTS:
As an ORACLE SYSADM, perform grants for create procedure, create library to the ORACLE_USER.

As the Linux user run load_wrappers.sh from the shell to actually create the wrappers. Make sure the ORACLE_HOME variable is set correctly so that $ORACLE_HOME gets substituted at run time.

For Example:
[oracle@oracle ~]$sh load_wrappers.sh

This will load the PLS Wrapper, and convert into PL/SQL native Functions and Procedures. 

*************************
Running the Test Scripts
*************************
SINGLE RECORD TEST
1. Edit the provided example script test_mdAddr.sql and set the LICENSE and the PATH to the Address data files and any add-ons you wish to test. If you do not have a License call Melissa Data at 800-800-6245 ext 3.

If you want to exercise the Address Object functionality of Parse, Street data, and ZIP data interfaces, also change the PATH and License for those scripts. Parse: test_mdParse.sql, Street Data: test_mdStreet.sql, ZIP Data: test_mdZip.sql. 

mdAddrSetLicenseString(ao, 'SET_LICENSE_HERE');
mdAddrSetPathToUSFiles(ao, 'SET_PATH_HERE');
mdAddrSetPathToDPVDataFiles(ao, 'SET_PATH_HERE');

Create the table to store the Object's return values.
CREATE TABLE "ORACLE_USER"."LOG" ( "VALUES" (4096))

2. From SQLPLUS execute the provided example test_mdAddr.sql to exercise the functionality of AddressObject's Address Check Interface. For example:

@test_mdAddr.sql

BATCH RECORDS TEST
1. To run the batch example: If you have not imported the data already, create a table and load the test data. For example:

CREATE TABLE "ORACLE_USER"."MD_APNE_TABLE" ( "FULLNAME" CHAR(30), "COMPANY" CHAR(50), "ADDRESS1" CHAR(50), "ADDRESS2" CHAR(50), "CITY" CHAR(30), "STATE" CHAR(10), "ZIP" CHAR(10), "EMAILADDRESS" CHAR(75), "PHONE" CHAR(20))

2. Next import the AddressPhoneNameEmail.csv into an Oracle Table using the provided APNE.ctl, SQLLDR control file. For example:

sqlldr control=APNE.ctl userid=ORACLE_USER/PASSWD

3. Execute the address_batch.sql to process the address records in the table.  For example:

@address_batch.sql

If you should have any questions, suggestions or improvements, please email Support at g-dqt@melissadata.com.

COPYRIGHT NOTICE
(C) 2012 Melissa Data Corporation. All rights reserved.



